//
//  Constant.swift
//  Sina
//
//  Created by 赵柏清 on 16/7/29.
//  Copyright © 2016年 DarkZhao. All rights reserved.
//

import UIKit

func printLog<T>(message: T,
    logError: Bool = false,
    file: String = __FILE__,
    method: String = __FUNCTION__,
    line: Int = __LINE__)
{
    if logError {
        print("\((file as NSString).lastPathComponent)[\(line)], \(method): \(message)")
    } else {
        #if DEBUG
            print("\((file as NSString).lastPathComponent)[\(line)], \(method): \(message)")
        #endif
    }
}

let AppKey = "2675580399"
let AppSecret = "861e275b272a1c5f43e6a13bee11eac3"
let redirectUri = "http://www.itcast.cn"
/// 欢迎界面通知名字
let kNotificationChangeViewController = "kNotificationChangeViewController"

// 随机颜色函数
func randomColor()->UIColor{
    return UIColor(red: CGFloat(random()) % 255, green: CGFloat(random()) % 255, blue: CGFloat(random()) % 255, alpha: 1)
}


//MARK:--
/// 屏幕宽高
let kUIScreenWidth = UIScreen.mainScreen().bounds.size.width
let KUIScreenHeight = UIScreen.mainScreen().bounds.size.height
